import Qt 4.7

Item {
    width: 100
    height: 62
    //property alias text: tIt.text

    property int num
    id: root
    property string tens : Math.floor(num / 10)
    property string ones : num % 10

    Image {
        id: imgTens
        source: "pic/numbers/" + tens + ".png"
        visible:  num >= 10

    }
    Image {
        anchors {
            left: imgTens.right
        }

        id: imgOnes
        source: "pic/numbers/" + ones + ".png"
    }


    function start(x_,y_, num_) {
        root.x = x_
        root.y = y_
        root.num = num_
        //text = txt
        animBounce.to = y_ - 50
        animBounce.start()

    }

    PropertyAnimation {
        id: animBounce
        target: root
        property: "y"

        duration: 2000

        easing.type: Easing.OutBounce
        onCompleted: {
            root.destroy()


        }
    }

}
